import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from "@/views/Home";
import Login from "@/views/Login";

Vue.use(VueRouter)

/**
 * 路由配置
 * @type {({path: string, component: {components: {Info: {name: string, props: [string]}}, data(): {query_info: {searchType: string, candidateNumber: string, studentName: string}, msg: string, showInfo: boolean, result_info: {}, queryCount: string}, methods: {query(): void, count(): void}, created(): void, name: string, vConsole: VConsole}, name: string}|{path: string, component: {data(): {msg: string}, methods: {gtouchstart(): void, gtouchend(): void, gtouchmove(): void}}})[]}
 */
const routes = [
  {
    path: '/',
    name: 'gotoLogin',
    redirect: {
      path: '/login'
    },
  },
  {
    path: '/login',
    name: 'Login',
    component: Login
  },
  {
    path: '/home',
    name: 'Home',
    component: Home
  },
]

const router = new VueRouter({
  routes
})

export default router
